// NPC Group Management for Group Behavior
#pragma once
#include <vector>
#include "NPC.h"

class NPCGroup
{
public:
    NPCGroup();
    ~NPCGroup();

    void AddNPC(NPC* npc);
    void RemoveNPC(NPC* npc);
    void Update(float deltaTime);

    // Group decision making
    void SetGroupTarget(GameObject* target);
    GameObject* GetGroupTarget() const { return m_pGroupTarget; }

    // Formation
    D3DXVECTOR3 GetFormationPosition(int index, const D3DXVECTOR3& centerPos);

    std::vector<NPC*>& GetMembers() { return m_members; }
    int GetMemberCount() const { return (int)m_members.size(); }

private:
    std::vector<NPC*> m_members;
    GameObject* m_pGroupTarget;
    D3DXVECTOR3 m_groupCenter;
};
